package org.yuyao.common.controller;

import org.yuyao.common.constant.HttpSatausConstant;
import org.yuyao.common.domain.vo.YuyaoResponse;

/**
 * @author yuyao
 * @date 2025-03-11 22:20:33
 * @description TODO
 */
public class BaseController {
    /**
     * 返回成功
     * @param data
     * @return
     */
    public YuyaoResponse success(Object data) {
        YuyaoResponse response = new YuyaoResponse();
        response.setData(data);
        response.setCode(HttpSatausConstant.SUCCESS);
        response.setMsg("成功");
        return response;
    }
}
